home *** CD-ROM | disk | FTP | other *** search
- NM(1) Last changed: 1-4-99
-
-
- NNAAMMEE
- nnmm - Print name list of object file(s)
-
- SSYYNNOOPPSSIISS
- nnmm [--bbddeeffgghhllnnoopprruuvvxxAABBCCTTVV] [_f_i_l_e_s]]
-
- IIMMPPLLEEMMEENNTTAATTIIOONN
- IRIX systems
-
- DDEESSCCRRIIPPTTIIOONN
- The nnmm command prints formatted listings of the symbol tables for each
- ELF _f_i_l_e specified. A _f_i_l_e can be a relocatable or absolute ELF
- object file, or it can be an archive.
-
- nnmm produces different output formats depending on options and the
- binary ABI. The differences are an attempt to preserve the operation
- of scripts that depend on nnmm. Anyone desiring consistent operation
- across different ABIs should use XPG4 format or Berkeley format.
-
- For old 32-bit-ABI objects the output format by default is the same as
- IRIX5.2 and 5.3 (something like AT&T System V Release 3 format).
-
- For new 32-bit-ABI objects the output format by is AT&T System V
- Release 4 format.
-
- For 64-bit objects the output format is by default in AT&T System V
- Release 4 format.
-
- If the __XXPPGG environment variable is defined, nnmm operates in
- conformance with the X/Open XPG4 specifications (called XXPPGG44 mmooddee in
- this document). The XPG4 mode format follows the XPG4 standards. In
- XPG4 mode, nnmm output looks somewhat like nnmm --BB (Berkeley style)
- output.
-
- When Using AT&T System V Release 4 format, the following information
- will be printed for each symbol (an alternative, Berkeley (4.3BSD)
- format, is described later in this man page):
-
- IInnddeexx The index of the symbol. (The index appears in brackets.)
-
- VVaalluuee The value of the symbol is one of the following: a section
- offset for defined symbols in a relocatable file; alignment
- constraints for symbols whose section index is SSHHNN__CCOOMMMMOONN; a
- virtual address in executable and dynamic library files.
-
- SSiizzee The size in bytes of the associated object.
-
- TTyyppee A symbol is one of the following types:
-
- NNOOTTYYPPEE
- No type was specified.
-
- OOBBJJEECCTT
- A data object such as an array or variable.
-
- FFUUNNCC A function or other executable code.
-
- SSEECCTTIIOONN
- A section symbol
-
- FFIILLEE Name of the source file.
-
- BBiinndd The symbol's binding attributes. LLOOCCAALL symbols have a scope
- limited to the object file containing their definition; GGLLOOBBAALL
- symbols are visible to all object files being combined; and
- WWEEAAKK symbols are essentially global symbols with a lower
- precedence than GGLLOOBBAALL.
-
- OOtthheerr A name scope indicator for (rrlldd()). One of DDEEFFAAUULLTT, IINNTTEERRNNAALL,
- HHIIDDDDEENN, PPRROOTTEECCTTEEDD. (see SSTTOO__DDEEFFAAUULLTT, etc in <<ssyyss//eellff..hh>>).
-
- SShhnnddxx Except for 3 special values, this is the section header table
- index in relation to which the symbol is defined. The
- following special values exist: AABBSS indicates the symbol's
- value will not change through relocation; CCOOMMMMOONN indicates an
- unallocated block and the value provides alignment
- constraints; and UUNNDDEEFF indicates an undefined symbol.
-
- NNaammee The name of the symbol.
-
- The nnmm command supports the options listed below. NNOOTTEE: The meaning
- of --oo depends on whether --AA(AT&T) or --BB is in effect when --oo is
- encountered (the meaning depends on the relative ordering of the
- options).
- Examples:
-
- nm -Bo a.out
- nm -oB a.out
-
- In the first example, oo is given the --BB meaning, while in the
- second, it is given the --AA (default) meaning.
-
- --AA Use AT&T System V Release 4 format output. This is the
- default for new 32-bit ABI objects and 64bit ABI objects. In
- XPG4 mode, --AA means write the full pathname of an object on
- each line.
-
- --BB Use Berkeley (4.3BSD) format output. Overrides XPG4 mode.
-
- --bb Print the value field in octal.
-
- --CC Print decoded C++ names.
-
- --dd Print the value field in decimal. This is the default value
- field radix for --AA.
-
- --ee Print externals and statics only. This option applies to 32-
- bit objects only and is ignored for 64-bit objects.
-
- --ff Produce full output. (This option is obsolete and does
- nothing and will be removed in a future release).
-
- --gg Print only globally-visible names.
-
- --hh Do not print headers.
-
- --ll Adds to the type field displayed in --pp format by printing a
- '*' for weak names. Has no effect on other formats or on --BB
- format.
-
- --nn When used alone or with --AA, sort symbols by name. By name is
- the default sort order for --BB.
-
- When used with --BB, sort all symbols by value.
-
- --oo When used alone or with --AA, print the value field in octal.
-
- When used with --BB, prepend the filename to output line. This
- is useful for using ggrreepp to search through nnmm libraries.
-
- --pp Produce easily parsable, terse output.
-
- --rr Prepend the name of the object file or archive to each output
- line (Berkeley or XPG style) or name (ATT or default style).
-
- --uu Print only undefined symbols.
-
- --vv Sort symbols by value.
-
- --xx Print value field in hexadecimal. This is the default value
- field radix for --BB.
-
- --TT Only applies to the 32-bit output format. Truncate long
- names, inserting a `*' as the last printed character. (Since
- symbol names have been moved to the last column, the problem
- of overflow is removed and this option is no longer
- necessary.)
-
- --VV Print version information on standard error.
-
- --PP In XPG4 mode, write information in a portable output format
- according to the XPG standard.
-
- --tt ffoorrmmaatt
- In XPG4 mode, write each numeric value in the specified
- format. The format should be one of the following:
-
- dd The offset will be written in decimal.
-
- oo The offset will be written in octal.
-
- xx The offset will be written in hexadecimal.
-
- NNMM --BB FFOORRMMAATT
- For 32-bit objects, nnmm --BB produces Berkeley output format with aaddddrreessss
- or vvaalluuee field followed by a lleetttteerr showing what section the symbol is
- in and the nnaammee of the symbol. Followed, if the symbol is a weak
- symbol, by ((wweeaakk)).
-
- The following section letters describe the information that nnmm
- generates:
-
- TT External text.
-
- tt Local text.
-
- DD External initialized data.
-
- dd Local initialized data.
-
- BB External zeroed data.
-
- bb Local zeroed data.
-
- AA External absolute.
-
- aa Local absolute.
-
- UU External undefined.
-
- GG External small initialized data.
-
- gg Local small initialized data.
-
- II Init section (IRIX4 static shared library initialization
- code).
-
- SS External small zeroed data.
-
- ss Local small zeroed data.
-
- RR External read only.
-
- rr Local read only.
-
- CC Common.
-
- EE Small common.
-
- The following section letters were frequently emitted by nnmm in earlier
- releases but are now rarely emitted.
-
- NN Nil storage class, compiler internal usage.
-
- VV External small undefined.
-
- bb Fortran based variable
-
- XX Exception data
-
- PP Procedure section (not a normal variable).
-
- FF Fini section.
-
- oo Non-GP data item (item not put in a small data area even
- though it may be small enough to fit).
-
- XXPPGG44 mmooddee
- In XPG4 mode the format is specified by the XPG4 standard. The output
- is sorted alphabetically by symbol name. The following information is
- output:
-
- Object or library name, if -A is specified
-
- Name Symbol name
-
- Type Symbol type, which will be one of the following single
- characters (or one of the Berkeley format letters where
- non-conflicting with the following list).
-
- A Global absolute symbol
-
- a Local absolute symbol
-
- B External zeroed data
-
- b Local zeroed data
-
- D Global data symbol
-
- d Local data symbol
-
- T Global text symbol
-
- t Local text symbol
-
- U Undefined symbol
-
- Value The value of the symbol.
-
- Size The size of the symbol (0 if size not available).
-
- NNOOTTEESS
- In some previous releases, the behavior of --rrBB was very different from
- --BBrr (in this case the rr did nothing). This did not appear to be
- intentional and was certainly undocumented. Now they both do the same
- thing.
-
- SSEEEE AALLSSOO
- ccoolllliiddee(1), eellffdduummpp(1), ddwwaarrffdduummpp(1), ssttdduummpp(1), oodduummpp(1), nnlliisstt(3e)
-
- This man page is available only online.
-
-